import reuquest from '@/utils/request.js'

// 列表
export const addressListApi = (data = {}, options = { loading: false }) => {
	return reuquest.post(`/apiagent/v1/address/list`, data, options)
}

// 详情
export const addressDetailsApi = (gid, data = {}, options = { loading: false }) => {
	return reuquest.post(`/apiagent/v1/address/details?gid=${gid}`, data, options)
}

// 新增
export const addressCreateApi = (data = {}, options = { loading: false }) => {
	return reuquest.post(`/apiagent/v1/address/create`, data, options)
}

// 编辑
export const addressEditApi = (gid, data = {}, options = { loading: false }) => {
	return reuquest.post(`/apiagent/v1/address/edit?gid=${gid}`, data, options)
}

// 删除
export const addressDeleteApi = (gid, data = {}, options = { loading: false }) => {
	return reuquest.post(`/apiagent/v1/address/delete?gid=${gid}`, data, options)
}
